@use 'sass:color';
@use 'variables' as *;

.login-container {
  position: relative;
  width: 100vw;
  height: 100vh;
  overflow: hidden;

  .background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;

    img {
      width: 100%;
      height: 100%;
      object-fit: cover;
    }
  }

  .header {
    position: relative;
    display: flex;
    align-items: center;
    padding: 20px 25px;
    margin-top: -20px;
    background: transparent;
    box-shadow: none;

    .logo-container {
      margin-top: -10px;
      width: 50px;
      margin-right: 40px;

      img {
        width: 200%;
      }
    }

    .title {
      h1 {
        font-family: $font-family-special;
        font-size: 30px;
        font-weight: bold;
        margin: 0;
        color: #333;
        letter-spacing: 2px;
      }

      p {
        font-size: 12px;
        margin: 0;
        color: #666;
      }
    }

    .subtitle {
      position: absolute;
      right: 80px;
      color: #666;
      font-size: 18px;
      letter-spacing: 3px;
    }
  }

  .decorations {
    position: absolute;
    left: 1%;
    top: 50%;
    transform: translateY(-40%);
    display: flex;
    align-items: center;

    .teacher-image {
      width: 800px;
      height: auto;
      position: relative;
      z-index: 2;
    }

    &::before {
      content: '';
      position: absolute;
      width: 250px;
      height: 250px;
      background: url('@/assets/images/login/circle.svg') no-repeat center/contain;
      right: 120px;
      top: 120px;
      z-index: 1;
    }
  }

  .login-form {
    position: absolute;
    right: 15%;
    top: 50%;
    transform: translateY(-50%);
    width: 450px;
    padding: 40px;
    background: transparent;
    border-radius: 8px;

    .form-header {
      display: flex;
      flex-direction: column;
      align-items: center;
      margin-bottom: 40px;
      
      .title-row {
        display: flex;
        align-items: center;
        gap: 15px;
        margin-bottom: -40px;
        margin-left: 40px;

        .form-logo {
          width: 40%;
          margin-top: -40px;
          margin-left: -40px;
        }
  
        h1 {
          font-family: $font-family-special;
          font-size: 100px;
          font-weight: bold;
          margin: 0;
          color: #000;
          letter-spacing: 1px;
        }
      }

      p {
        font-size: 18px;
        margin: 15px 0 0;
        color: #666;
        letter-spacing: 2px;
        font-family: $font-family-base;
        position: relative;
        padding-bottom: 8px;
        
        &::after {
          content: '';
          position: absolute;
          bottom: 0;
          left: 50%;
          transform: translateX(-50%);
          width: 40px;
          height: 2px;
          background: linear-gradient(to right, #95d475, #67C23A);
          border-radius: 1px;
        }
      }
    }

    .el-input {
      margin-bottom: 25px;
      
      .el-input__wrapper {
        background-color: #f5f7fa;
        border: none;
        box-shadow: none !important;
        padding: 1px 15px;
        height: 40px;
      }

      .el-input__inner {
        height: 40px;
        font-size:15px;
      }

      // .el-input__suffix {
      //   cursor: pointer;
        
      //   .el-input__icon {
      //     &:hover {
      //       color: var(--el-color-primary);
      //     }
      //   }
      // }
    }

    .code-item {
      display: flex;
      gap: 10px;
      margin-bottom: 20px;

      .el-input {
        margin-bottom: 0;
      }

      .code-image {
        width: 120px;
        height: 40px;
        cursor: pointer;

        img {
          width: 100%;
          height: 100%;
          object-fit: cover;
          border-radius: 4px;
        }
      }
    }

    .login-button {
      width: 100%;
      height: 48px;
      background: #95d475;
      border: none;
      border-radius: 4px;
      font-size: 17px;

      &:hover {
        background: #85c665;
      }
    }
  }

  .watermark {
    position: fixed;
    left: 0px;
    bottom: -100px;
    font-family: $font-family-special;
    font-size: 300px;
    font-weight: bold;
    color: rgba(0, 0, 0, 0.03);
    z-index: -1;
    user-select: none;
    pointer-events: none;
  }
}

// Element Plus 样式覆盖
:deep(.el-input__wrapper) {
  background-color: transparent;
  box-shadow: none;
  border-radius: 4px;
  padding: 1px 11px;
  border-bottom: 1px solid #dcdfe6;
}

:deep(.el-input__inner) {
  height: 40px;
  background-color: transparent;
}

.cursor-pointer {
  cursor: pointer;
  &:hover {
    color: var(--el-color-primary);
  }
} 